﻿{strip}
	<br />

	{if ($smarty.session.CMS.user_level >= 1000) OR (($smarty.session.CMS.user_flags.content_menu_overview))}
		<div style="float:left;width:315px;margin-left:20px;">

		{if 0 < $widgets|@count}
			
			{foreach from=$widgets item="item"}

				<h3 title="Test">{$item.title}</h3>
				<div class="contentbox">
					<div class="contentbox_header">&nbsp;</div>
					<div class="contentbox_inner">
						{$item.content}
					</div> {* /contentbox_inner *}
				</div> {* /contentbox *}
				<br />
			{/foreach}
		
		{/if}

		{if  ($obj.permissions.modify == 1)  }
				{* Box: Properties ---------------------------------------------------------------------------------------------*}
				<h3 title="Test">{$smarty.config.ContentPreferences_properties}</h3>
				<div class="contentbox">
					<div class="contentbox_header">&nbsp;</div>
					<div class="contentbox_inner">
						<form name="formObjReName_{$obj.obj_id}" id="formObjReName_{$obj.obj_id}">
							<input type="hidden" name="obj_id" value="{$obj.obj_id}" />
							<input type="hidden" name="obj_vers_id" value="{$obj.obj_vers_id}" />
							<div class="box_label">
								{$smarty.config.ContentPreferences_new_obj_name_value}
							</div>
							<div class="box_content">
								<input type="text" name="obj_name_name" value="{$obj.obj_name_name|htmlentitiesutf8}" class="FormFieldInput" style="width: 167px;" />
								<br />
								<input type="checkbox" id="obj_is_navi{$obj.obj_id}" name="obj_is_navi"  value="1" {if $obj.obj_is_navi==1}checked="checked"{/if} class="formtype_checkbox" />
								<label for="obj_is_navi{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_properties_isnavi}</label>
								<div class="clear"></div>
								<input type="checkbox" id="obj_no_elements{$obj.obj_id}" name="obj_no_elements"  value="1" {if $obj.obj_no_elements==1}checked="checked"{/if} class="formtype_checkbox" />
								<label for="obj_is_navi{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_properties_noelements}</label>
								<div class="clear"></div>

								<input type="checkbox" id="obj_cacheable_{$obj.obj_id}" name="obj_cacheable"  value="1" {if $obj.obj_cacheable==1}checked="checked"{/if} class="formtype_checkbox" />
								<label for="obj_cacheable_{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_properties_cache}</label>
								<div class="clear"></div>

								<input type="checkbox" id="obj_preview_{$obj.obj_id}" name="obj_preview"  value="1" {if $obj.obj_preview==1}checked="checked"{/if} class="formtype_checkbox" />
								<label for="obj_preview_{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">in der Vorschau anzeigen</label>
								<div class="clear"></div>

							</div>
							<div class="clear"></div>
							<hr />
							<br />
							<div class="box_label">
								{$smarty.config.ContentPreferences_properties_template}
							</div>
							<div class="box_content">
								<select name="obj_key_tpl_id" style="width: 180px;">
									<option value="0">---</option>
									{foreach name="tplloop" item=tpl from=$templates}
										<option value="{$tpl.tpl_id|stripslashes}" {if $obj.obj_key_tpl_id==$tpl.tpl_id}selected="selected"{/if}>{$tpl.tpl_name}</option>
									{/foreach}
								</select>
								<br />
								<input type="checkbox" name="apply_linked" value="1" id="apply_linked_{$obj.obj_id}" class="formtype_checkbox" />
								<label for="apply_linked_{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_properties_leave}</label>
								<div class="clear"></div>
								<br />
								<input type="button" name="" value="{$smarty.config.ContentPreferences_submitbt}" onclick="{literal}xajax.request({ccdsclass:'ccdsContentEditor',ccdsfun:'ContentEditorOverviewRenameObj'},{parameters:[xajax.getFormValues('formObjReName_{/literal}{$obj.obj_id}{literal}')]});{/literal}"/>
							</div>
							<div class="clear"></div>
						</form>
					</div> {* /contentbox_inner *}
				</div> {* /contentbox *}
				<br />
		{/if}
			{* Box: New Object ---------------------------------------------------------------------------------------------*}
			{if $obj.permissions.new == 1 && 0 < count($classes)}
				<h3>{$smarty.config.ContentPreferences_new_object} <a href="javascript:void(0);" class="info" style="position:relative;">[?]<span>{$smarty.config.ContentPreferences_new_object_hint}</span></a></h3>
				<div class="contentbox">
					<div class="contentbox_header">&nbsp;</div>
					<div class="contentbox_inner">
						<form name="addobjform_{$obj.obj_id}" id="addobjform_{$obj.obj_id}" action="" onsubmit="return false;">
							<input type="hidden" name="obj_parent_obj_id" id="obj_parent_obj_id" value="{$obj.obj_id}" />
							<div class="box_label">
								{$smarty.config.ContentPreferences_new_obj_name_value}
							</div>
							<div class="box_content">
								<input type="text" name="obj_name" id="add_obj_obj_name_{$obj.obj_id}" style="width: 167px;" value="" />
							</div>
							<div class="clear"></div>
							<div class="box_label">
								{$smarty.config.ContentPreferences_new_obj_select_value}
							</div>
							<div class="box_label">
								<select name="obj_key_class_id" style="width: 180px;">
									{foreach name="classloop" item=class from=$classes}
										<option value="{$class.class_id}" {if $smarty.session.CMS.last_inserted_class == $class.class_id}selected="selected"{/if}>{$class.class_name|stripslashes}</option>
									{/foreach}
								</select>
							</div>
							<div class="clear"></div>
							<div class="box_label">&nbsp;</div>
							<div class="box_content">
								<input type="checkbox" name="jump_to_obj" id="jump_to_obj_{$obj.obj_id}" value="1" class="formtype_checkbox" {if $smarty.session.CMS.session.jump_to_obj==1}checked="checked"{/if} />
								<label for="jump_to_obj_{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_new_obj_jump2}</label>
								
								<input type="checkbox" id="first_pos_{$obj.obj_id}" name="first_pos" value="1" class="formtype_checkbox" {if $smarty.session.CMS.session.first_pos==1}checked="checked"{/if} />
								<label for="first_pos_{$obj.obj_id}" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_new_first}</label>
								<div class="clear"></div>
								<br />
								<input type="button" name="addobjbtn" value="hinzuf&uuml;gen" onclick="{literal}xajax.request({ccdsclass:'ccdsContentEditor',ccdsfun:'ContentAddObj'},{parameters:[xajax.getFormValues('addobjform_{/literal}{$obj.obj_id}{literal}')]});{/literal};xajax.$('add_obj_obj_name_{$obj.obj_id}').value='';return false;" />
							</div>
							<div class="clear"></div>
						</form>
					</div> {* /contentbox_inner *}
				</div> {* /contentbox *}
				<br />
			{/if}
			
			{* Box: Copy/Move/Delete Object ---------------------------------------------------------------------------------------------*}
			<h3>{$smarty.config.ContentPreferences_fileactions}</h3>
			<div class="contentbox">
				<div class="contentbox_header">&nbsp;</div>
				<div class="contentbox_inner">
					<form name="content_action_form_{$obj.obj_id}" id="content_action_form_{$obj.obj_id}">
						<input type="hidden" name="obj_id" id="obj_id" value="{$obj.obj_id}" />
						<div class="box_label">
							{$smarty.config.ContentPreferences_fileactions_value}
						</div>
						<div class="box_content">
							<select size="1" id="obj_action_{$obj.obj_id}" name="obj_action" style="width: 180px;">
									<option value="">--</option>
									{if is_array($smarty.session.CMS.ACTION)}
										{if 
											(
											($smarty.session.CMS.ACTION.do == "copy") 
											OR
											($smarty.session.CMS.ACTION.obj.obj_parent_obj_id != $obj.obj_id AND 
													(
														$smarty.session.CMS.ACTION.do == "cut" 
														AND ! $smarty.session.CMS.ACTION.obj.obj_id|is_in_tree_recursive:$obj.obj_id
													)
											)
											AND ($smarty.session.CMS.ACTION.obj.obj_id != $obj.obj_id)
											)
											AND ($obj.permissions.new == 1)
										}
											{assign var="lang" value=$smarty.session.CMS.lang[$project_id]}
											<option value="paste" style="font-style:italic;">Objekt "{$smarty.session.CMS.ACTION.name[$lang]}"einfügen </option>
										{/if}
									{/if}
									<option value="clone">duplizieren</option>
									<option value="copy">kopieren</option>
									<option value="cut">ausschneiden</option>
								{if $obj.permissions.delete == 1}
									<option value="del">dieses Objekt löschen</option>
									<option value="clear">Unterobjekte löschen</option>
								{/if}
							</select><br />
							<input type="checkbox" name="obj_action_recursive" id="obj_action_recursive" class="formtype_checkbox" />
							<label for="obj_action_recursive" class="formtype_checkbox_label" style="width:150px;">{$smarty.config.ContentPreferences_fileactions_checkboxlabel}</label>
							<div class="clear"></div>
							<br />
							<input type="button" name="" value="ausführen" onclick="CMS.doContentEditorOverviewAction({$obj.obj_id})"/>
							<div class="clear"></div>
						</div>
						<div class="clear"></div>
					</form>
				</div> {* /contentbox_inner *}
			</div> {* /contentbox *}
			<br />
			
	

		</div>
	
		<div style="float:left;width:315px;margin-left:20px;">
			{if $obj.permissions.modify == 1}
			
				{* Box: Publish Settings ---------------------------------------------------------------------------------------------*}
				<h3>{$smarty.config.ContentPreferences_publish_settings}</h3>
				<div class="contentbox">
					<div class="contentbox_header">&nbsp;</div>
					<div class="contentbox_inner">
						<form name="form_obj_edit_{$obj.obj_id}" id="form_obj_edit_{$obj.obj_id}">
							<input type="hidden" name="obj_id" value="{$obj.obj_id}" />
							{foreach from=$project_languages item=lang}
								<img src="{$CMS_LIBRARY_WEB}famfamfam/flags/png/{$lang.lang_code}.png" border="0"> <strong>{$lang.lang_name}</strong><br />
								<div style="padding-left:16px;">
									<input type="checkbox" name="obj_is_public[{$lang.lang_id}]" id="obj_is_public_{$lang.lang_id}_{$obj.obj_id}" {if $obj_public[$lang.lang_id]==1}checked="checked"{/if} class="formtype_checkbox" />
									<label for="obj_is_public_{$lang.lang_id}_{$obj.obj_id}" class="formtype_checkbox_label" style="width:240px;">{$smarty.config.ContentPreferences_publish_set}</label>
									<div class="clear"></div>
									<input type="checkbox" name="visible_childs[{$lang.lang_id}]" id="visible_childs_{$lang.lang_id}_{$obj.obj_id}" class="formtype_checkbox" />
									<label for="visible_childs_{$lang.lang_id}_{$obj.obj_id}" class="formtype_checkbox_label" style="width:240px;">{$smarty.config.ContentPreferences_publish_below}</label>
									<div class="clear"></div>
								</div>
								<hr />
								<br />
							{/foreach}
							<input type="checkbox" name="apply_linked" value="1" id="apply_linked" checked="checked" class="formtype_checkbox" />
							<label for="apply_linked" class="formtype_checkbox_label" style="width:240px;">{$smarty.config.ContentPreferences_publish_leave}</label>
							<div class="clear"></div>
							<br />
							<input type="button" name="" onclick="{literal}xajax.request({ccdsclass:'ccdsContentEditor',ccdsfun:'ContentEditorOverviewUpdate'},{parameters:[xajax.getFormValues('form_obj_edit_{/literal}{$obj.obj_id}{literal}')]});{/literal}" value="{$smarty.config.ContentPreferences_submitbt}" />
							<div class="clear"></div>
						</form>
					</div> {* /contentbox_inner *}
				</div> {* /contentbox *}
				<br />
					{* Box: Lifetime ---------------------------------------------------------------------------------------------*}
			<h3>{$smarty.config.ContentPreferences_lifetime}</h3>
			<div class="contentbox">
				<div class="contentbox_header">&nbsp;</div>
				<div class="contentbox_inner">
					<form name="content_expire_form_{$obj.obj_id}" id="content_expire_form_{$obj.obj_id}" onsubmit="return false;">
						<input type="hidden" name="obj_id" id="obj_id" value="{$obj.obj_id}"  />
						<input type="checkbox" name="obj_expire" id="obj_expire" value="1" {if $obj.obj_expire ==1}checked="checked"{/if} class="formtype_checkbox" />
						<label for="obj_expire" class="formtype_checkbox_label" style="width:260px;">{$smarty.config.ContentPreferences_lifetime_activate}</label>
						<div class="clear"></div>
						<hr />
						
						{$smarty.config.ContentPreferences_lifetime_start}<br />
						<select name="obj_expire_start_day" id="obj_expire_start_day" size="1" class="date_selectbox">
							{foreach name="valueloop" from=$obj.days item=value}
								<option value="{$value}" {if $value== $obj.obj_expire_start|date_format:"%d"}selected="selected"{/if}>{$value}</option>
							{/foreach}		
						</select>
						<select name="obj_expire_start_month" id="obj_expire_start_month" size="1" class="date_selectbox">
							{foreach name="valueloop" from=$obj.months item=value}
								<option value="{$value}" {if $value== $obj.obj_expire_start|date_format:"%m"}selected="selected"{/if}>{$value}</option>
							{/foreach}		
						</select>&nbsp;
						<input type="text" name="obj_expire_start_year" id="obj_expire_start_year" value="{$obj.obj_expire_start|date_format:"%Y"}" class="date" />&nbsp;
						{$smarty.config.ContentPreferences_lifetime_time}&nbsp;
						<input type="text" name="obj_expire_start_hour" id="obj_expire_start_hour" value="{$obj.obj_expire_start|date_format:"%H"}" class="time" />:
						<input type="text" name="obj_expire_start_minute" id="obj_expire_start_minute" value="{$obj.obj_expire_start|date_format:"%M"}" class="time" />
						<br />
						
						{$smarty.config.ContentPreferences_lifetime_end}<br />
						<select name="obj_expire_end_day" id="obj_expire_end_day" size="1" class="date_selectbox">
							{foreach name="valueloop" from=$obj.days item=value}
								<option value="{$value}" {if $value== $obj.obj_expire_end|date_format:"%d"}selected="selected"{/if}>{$value}</option>
							{/foreach}		
						</select>	
						<select name="obj_expire_end_month" id="obj_expire_end_month" size="1" class="date_selectbox">
							{foreach name="valueloop" from=$obj.months item=value}
								<option value="{$value}" {if $value== $obj.obj_expire_end|date_format:"%m"}selected="selected"{/if}>{$value}</option>
							{/foreach}		
						</select>&nbsp;
						<input type="text" name="obj_expire_end_year" id="obj_expire_end_year" value="{$obj.obj_expire_end|date_format:"%Y"}"  class="date" />&nbsp;
						{$smarty.config.ContentPreferences_lifetime_time}&nbsp;
						<input type="text" name="obj_expire_end_hour" id="obj_expire_end_hour" value="{$obj.obj_expire_end|date_format:"%H"}" class="time" />:
						<input type="text" name="obj_expire_end_minute" id="obj_expire_end_minute" value="{$obj.obj_expire_end|date_format:"%M"}" class="time" />
						<br /><br />
						<input type="checkbox" name="obj_expire_del" id="obj_expire_del" value="1" {if $obj.obj_expire_del ==1}checked="checked"{/if} class="formtype_checkbox" />
						<label for="obj_expire_del" class="formtype_checkbox_label" style="width:260px;">{$smarty.config.ContentPreferences_lifetime_delete}</label>
						<div class="clear"></div>
						
						<input type="checkbox" name="apply_linked" value="1" id="apply_linked" checked="checked" class="formtype_checkbox" />
						<label for="apply_linked" class="formtype_checkbox_label" style="width:260px;">{$smarty.config.ContentPreferences_lifetime_leave}</label>
						<div class="clear"></div>
						<br />
						<input type="submit" class="submitbtn" value="speichern" onclick="{literal}xajax.request({ccdsclass:'ccdsContentEditor',ccdsfun:'ContentEditorExpire'},{parameters:[xajax.getFormValues('content_expire_form_{/literal}{$obj.obj_id}{literal}')]});{/literal}" />
						<div class="clear"></div>
					</form>
				</div> {* /contentbox_inner *}
			</div> {* /contentbox *}
			<br />
		

					
		
				{if $obj.INJECTION != ""}
					<br/>
					{include file=$obj.INJECTION}
				{/if}
				
			{/if}	
			<div style="clear:both;"></div>
		</div>
		<div style="clear:both;"></div>
	{/if}
{/strip}